package com.ruoyi.system.service.impl;

import java.util.List;


import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.PositionMapper;
import com.ruoyi.system.domain.Position;
import com.ruoyi.system.service.IPositionService;

/**
 * positionService业务层处理
 *
 * @author ruoyi
 * @date 2024-03-20
 */
@Service
public class PositionServiceImpl implements IPositionService
{
    @Autowired
    private PositionMapper positionMapper;


    /**
     * 查询position
     *
     * @param id position主键
     * @return position
     */
    @Override
    public Position selectPositionById(Long id)
    {
        return positionMapper.selectPositionById(id);
    }

    /**
     * 查询position列表
     *
     * @param position position
     * @return position
     */
    @Override
    public List<Position> selectPositionList(Position position)
    {
        return positionMapper.selectPositionList(position);
    }

    /**
     * 新增position
     *
     * @param position position
     * @return 结果
     */
    @Override
    public int insertPosition(Position position)
    {
        return positionMapper.insertPosition(position);
    }

    /**
     * 修改position
     *
     * @param position position
     * @return 结果
     */
    @Override
    public int updatePosition(Position position)
    {
        return positionMapper.updatePosition(position);
    }

    /**
     * 批量删除position
     *
     * @param ids 需要删除的position主键
     * @return 结果
     */
    @Override
    public int deletePositionByIds(Long[] ids)
    {
        return positionMapper.deletePositionByIds(ids);
    }

    /**
     * 删除position信息
     *
     * @param id position主键
     * @return 结果
     */
    @Override
    public int deletePositionById(Long id)
    {
        return positionMapper.deletePositionById(id);
    }
}
